//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package com.graphite.util;

import com.fasterxml.jackson.core.type.TypeReference;
import sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl;

import java.lang.reflect.Type;
import java.util.List;

/**
 * 类型映射工具类
 */
public class TypeReferenceUtil {
    public TypeReferenceUtil() {
    }

    public static TypeReference<List> getListReference(Type clz) {
        Type[] types = new Type[]{clz};
        final ParameterizedTypeImpl type = ParameterizedTypeImpl.make(List.class, types, List.class.getDeclaringClass());
        return new TypeReference<List>() {
            public Type getType() {
                return type;
            }
        };
    }
}
